package com.cow.support.entity;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;

/**
 * Roleinfo entity. @author MyEclipse Persistence Tools
 */

public class Roleinfo implements java.io.Serializable {

	// Fields

	private Long roleid;
	private String name;
	private String description;
	private String roletype;
	private Date gentime;
	private Set orgroles = new HashSet(0);

	// Constructors

	/** default constructor */
	public Roleinfo() {
	}

	/** minimal constructor */
	public Roleinfo(Long roleid, String name, String description, Date gentime,String roletype) {
		this.roleid = roleid;
		this.name = name;
		this.description = description;
		this.gentime = gentime;
		this.roletype = roletype;
	}

	/** full constructor */
	public Roleinfo(Long roleid, String name, String description, Date gentime,String roletype,
			Set orgroles) {
		this.roleid = roleid;
		this.name = name;
		this.description = description;
		this.gentime = gentime;
		this.roletype = roletype;
		this.orgroles = orgroles;
	}

	// Property accessors

	public Long getRoleid() {
		return this.roleid;
	}

	public void setRoleid(Long roleid) {
		this.roleid = roleid;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getDescription() {
		return this.description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public Date getGentime() {
		return this.gentime;
	}

	public void setGentime(Date gentime) {
		this.gentime = gentime;
	}

	public Set getOrgroles() {
		return this.orgroles;
	}

	public void setOrgroles(Set orgroles) {
		this.orgroles = orgroles;
	}
	
	public String getRoletype() {
		return roletype;
	}

	public void setRoletype(String roletype) {
		this.roletype = roletype;
	}

	public boolean equals(Object obj) {
        if (this == obj)
            return true;
        if (obj == null)
            return false;
        if (getClass() != obj.getClass())
            return false;
        final Roleinfo other = (Roleinfo) obj;
        if(this.getRoleid()!=other.getRoleid())
            return false;
        return true;
   }

}